package day05;

public class Test03 {
    public static void main(String[] args) {
        int[] array={7,8,1,3,5};
        int max=maxi(array);
        System.out.println("该数组的最大值是:"+max);
    }
    public static int maxi(int[] arr){
        int max=arr[0];
        for(int i=0;i<arr.length-1;i++){
            if(arr[i]>max) 
            max=arr[i];
        

        }
        return max;

    }



}
